package org.kgc.alanhealth.entity;

import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName hospital_useraddress
 */
@Data
public class HospitalUseraddress implements Serializable {
    /**
     * 
     */
    private Integer id;

    /**
     * 收件人
     */
    private String consignee;

    /**
     * 收件人联系电话
     */
    private String consigneephone;

    /**
     * 用户地址
     */
    private String useraddress;

    /**
     * 对应用户的id
     */
    private Integer userid;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HospitalUseraddress other = (HospitalUseraddress) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getConsignee() == null ? other.getConsignee() == null : this.getConsignee().equals(other.getConsignee()))
            && (this.getConsigneephone() == null ? other.getConsigneephone() == null : this.getConsigneephone().equals(other.getConsigneephone()))
            && (this.getUseraddress() == null ? other.getUseraddress() == null : this.getUseraddress().equals(other.getUseraddress()))
            && (this.getUserid() == null ? other.getUserid() == null : this.getUserid().equals(other.getUserid()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getConsignee() == null) ? 0 : getConsignee().hashCode());
        result = prime * result + ((getConsigneephone() == null) ? 0 : getConsigneephone().hashCode());
        result = prime * result + ((getUseraddress() == null) ? 0 : getUseraddress().hashCode());
        result = prime * result + ((getUserid() == null) ? 0 : getUserid().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", consignee=").append(consignee);
        sb.append(", consigneephone=").append(consigneephone);
        sb.append(", useraddress=").append(useraddress);
        sb.append(", userid=").append(userid);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}